<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>航班查询</title>
<!-- 新 Bootstrap 核心 CSS 文件 -->
<link rel="stylesheet"
	href="//cdn.bootcss.com/bootstrap/3.3.5/css/bootstrap.min.css">

<!-- 可选的Bootstrap主题文件（一般不用引入） -->
<link rel="stylesheet"
	href="//cdn.bootcss.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">

<!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
<script src="//cdn.bootcss.com/jquery/1.11.3/jquery.min.js"></script>

<!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
<script src="//cdn.bootcss.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>

</head>
<body>
	<div class="container-fluid">
	<div class="jumbotron"></div>
	<div class="row">
		<div class="row col-md-4 col-sm-1"></div>
		<div class="row col-md-4 col-sm-10">
			<#if result??> <#if result.code != 0>
			<div class="alert alert-danger alert-dismissible" role="alert">
				<button type="button" class="close" data-dismiss="alert"
					aria-label="Close">
					<span aria-hidden="true">&times;</span>
				</button>
				<strong>错误!</strong> ${(result.message)!}
			</div>
			</#if> 
			<#elseif fnoMsg??>
			<div class="alert alert-danger alert-dismissible" role="alert">
				<button type="button" class="close" data-dismiss="alert"
					aria-label="Close">
					<span aria-hidden="true">&times;</span>
				</button>
				<strong>错误!</strong> ${fnoMsg!}
			</div>
			</#if>
		</div>
		<div class="row col-md-4 col-sm-1"></div>
	</div>
	<div class="container-fluid">
		<div class="row col-md-4 col-sm-1"></div>
		<div class="row col-md-4 col-sm-10">
			<form method="post" action="/flightinfo/search">
				<div class="form-group">
					<label class="sr-only" for="exampleInputAmount">Amount
						(indollars)</label>
					<div class="input-group">
						<div class="input-group-addon">
							<span class="glyphicon glyphicon-plane" aria-hidden="true"></span>
						</div>
						<input type="text" class="form-control" id="fno" name="fno"
							placeholder="请输入航班号" value='${fno!}'>
					</div>
				</div>
				<button type="submit" class="btn btn-primary col-sm-12">点击查询</button>
			</form>
		</div>
		<div class="row col-md-4 col-sm-1"></div>
	</div>
	<#if result??> <#if result.code = 0>
	<div class="row">
		<div class="page-header col-md-10 col-md-offset-1">
			<h1>
				<small>航班日期[${(result.searchTime?string('yyyy-MM-dd'))}]</small>
			</h1>
		</div>
	</div>

	<div class="row">
		<div class="col-md-10 col-md-offset-1">
			<table class="table table-condensed table-hover table-bordered">

				<tr class='active'>
					<th>航班号</th>
					<th>计划起飞时间<br />出发机场/航站楼
					</th>
					<th>计划降落时间<br />降落机场/航站楼
					</th>
					<th>准点率</th>
					<th>状态</th>
					<th>预计起飞时间<br />预计降落时间
					</th>
					<th>实际起飞时间<br />实际降落时间
					</th>
				</tr>
				<#list result.trendsList as trends>
				<tr>
					<td>${(result.flightInfo.fno)!}</td>
					<td class="info">
						${(trends.jhqfTime)!} <br />
						${(trends.fromCity)!}
					</td>
					<td class="info">
						${(trends.jhddTime)!} <br />
						${(trends.toCity)!}
					</td>
					<td>
						${(result.flightInfo.zdl)!}
					</td>
					<td class="warning">
						${(trends.flightStatus)!}
					</td>
					<td>
						${(trends.yjqfTime)!} <br />
						${(trends.yjddTime)!}
					</td>
					<td class="success">
						${(trends.sjqfTime)!} <br />
						${(trends.sjddTime)!}
					</td>
				</tr>
				</#list>
			</table>
		</div>
	</div>
	</#if> </#if>
	</div>
</body>
</html>